import req from '@/utils/request'

// 新增员工
export function addInfo(data) {
  return req.post('/api/human/employeeBaseInfor', data)
}

// 修改员工
export function editInfo(data) {
  return req.put('/api/human/employeeBaseInfor', data)
}

// 查询员工列表分页查询
export function getInfoList(data) {
  return req.post('/api/human/employeeBaseInfor/page', data)
}

// 导出Excel
export function exportList(data) {
  return req.post('/api/human/employeeBaseInfor/export', data, 'blob')
}

// 导入Excel
export function importList(data) {
  return req.post('/api/human/employeeBaseInfor/import', data)
}

// 查询员工回收站列表分页查询
export function getInfoListDump(data) {
  return req.post('/api/human/employeeBaseInfor/recyclingPage', data)
}

// 查询员工回收站列表分页查询
export function editInfoListDump(params) {
  return req.put('/api/human/employeeBaseInfor/restore', params)
}

// 查询员工列表单体查询
export function getInfo(id) {
  return req.get(`/api/human/employeeBaseInfor/${id}`)
}

// 删除员工信息
export function deleteInfo(data) {
  return req.delete('/api/human/employeeBaseInfor', { data })
}

// 修改员工工作经历
export function editWorkHistroy(data) {
  return req.put('/api/human/employeeBaseInfor/workHistroyUpdate', data)
}

// 修改员工工作经历
export function deleteWorkHistroy(params) {
  return req.delete('/api/human/employeeBaseInfor/workHistroyDelById', {
    params
  })
}

// 获取员工工作经历
export function getWorkHistroy(data) {
  return req.get('/api/human/employeeBaseInfor/workHistroyList', data)
}

// 修改员工教育经历
export function editEducation(data) {
  return req.put('/api/human/employeeBaseInfor/educationUpdate', data)
}

// 删除员工教育经历
export function deleteEducation(params) {
  return req.delete('/api/human/employeeBaseInfor/educationDelById', { params })
}

// 获取员工教育经历
export function getEducation(data) {
  return req.get('/api/human/employeeBaseInfor/educationList', data)
}

// 修改员工联系方式
export function editContact(data) {
  return req.put('/api/human/employeeBaseInfor/contactUpdate', data)
}

// 获取员工联系方式
export function getContact(data) {
  return req.get('/api/human/employeeBaseInfor/contactList', data)
}

// 删除员工联系方式
export function deleteContact(params) {
  return req.delete('/api/human/employeeBaseInfor/contactDelById', { params })
}

// 修改员工银行卡信息
export function editBankCard(data) {
  return req.put('/api/human/employeeBaseInfor/bankCardUpdate', data)
}

// 删除员工银行卡信息
export function deleteBankCard(params) {
  return req.delete('/api/human/employeeBaseInfor/bankCardDelById', { params })
}

// 获取员工银行卡信息
export function getBankCard(data) {
  return req.get('/api/human/employeeBaseInfor/bankCardList', data)
}

// 员工入职
export function staffEntry(data) {
  return req.post('/api/human/employeeBaseInfor/entry', data)
}

// 员工转正
export function staffPositive(data) {
  return req.put('/api/human/employeeBaseInfor/positive', data)
}

// 员工转正
export function staffDeparture(data) {
  return req.put('/api/human/employeeBaseInfor/departure', data)
}

// 员工转入项目
export function intoProject(data) {
  return req.post('/api/human/employeeBaseInfor/intoProject', data)
}

// 员工转出项目
export function outProject(data) {
  return req.put('/api/human/employeeBaseInfor/outProject', data)
}

// 获取员工就职信息
export function getWorkInfor(data) {
  return req.get('/api/human/employeeBaseInfor/getWorkInfor', data)
}

// 获取员工项目信息
export function getProjectInfor(data) {
  return req.get('/api/human/employeeBaseInfor/getProjectInfor', data)
}

// 获取员工可转入项目信息
export function getProjects(data) {
  return req.get('/api/human/employeeBaseInfor/getProjects', data)
}

// 获取员工可签约签约主体
export function getContractSubject(data) {
  return req.get('/api/human/employeeBaseInfor/getContractSubject', data)
}
